<?php

/*
 * Niken Larasati
 * larasati.n@students.amikom.ac.id
 */

class pendidikan extends CI_Controller {

    public function __construct() {
        parent::__construct();
    }

    function form_pendidikan() {
        $this->template->load('halaman_v', 'form_pendidikan_v');
    }

    function tambah() {
        if ($this->input->post('tambah') != NULL)
            ; {
                $data['id_didik'] = $this->input->post('id_pendidikan');
                $data['pendidikan'] = $this->input->post('pendidikan');
                
                $this->load->model('umum_m');
                $this->umum_m->tambah('pendidikan',$data);
                $this->template->load('halaman_v', 'form_pendidikan_v');           
        }
    }
    
    function ambil_data(){
        $this->load->model('pendidikan_m');
        $data['data'] = $this->pendidikan_m->ambil_data();
        $this->template->load('halaman_v', 'form_pendidikan_v',$data);
    }

}

?>
